import request from '@/utils/request'

// 查询年度种植作物列表
export function listWiCropY(query) {
  return request({
    url: '/distribute/WiCropY/list',
    method: 'get',
    params: query
  })
}

// 查询年度种植作物详细
export function getWiCropY(cropYr) {
  return request({
    url: '/distribute/WiCropY/' + cropYr,
    method: 'get'
  })
  // return request({
  //   url: '/distribute/WiCropY/query',
  //   method: 'get',
  //   params: query
  // })
}

// 新增年度种植作物
export function addWiCropY(data) {
  return request({
    url: '/distribute/WiCropY',
    method: 'post',
    data: data
  })
}

// 修改年度种植作物
export function updateWiCropY(data) {
  return request({
    url: '/distribute/WiCropY',
    method: 'put',
    data: data
  })
}

// 删除年度种植作物
export function delWiCropY(cropYr) {
  return request({
    url: '/distribute/WiCropY/' + cropYr,
    method: 'delete'
  })
}
